package com.wr.hangzhounewlight.controller.frontend;

import com.wr.hangzhounewlight.obj.dto.frontend.R;
import com.wr.hangzhounewlight.obj.dto.frontend.SiloManagementDTO;
import com.wr.hangzhounewlight.service.frontend.SiloManagementService;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author yuanzhizhuo
 * createDate 2025/11/14
 */
@CrossOrigin
@RestController
public class SiloManagementController {

    private final SiloManagementService siloManagementService;

    public SiloManagementController(SiloManagementService siloManagementService) {
        this.siloManagementService = siloManagementService;
    }

    @PostMapping("/query-silo")
    public R querySilo(@RequestBody SiloManagementDTO dto) {
        return siloManagementService.querySilo(dto);
    }

}
